package com.ctgu.expresshelper.service.address.impl;

import com.ctgu.expresshelper.dao.AddressDao;
import com.ctgu.expresshelper.entity.Address;
import com.ctgu.expresshelper.service.address.AddressService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class AddressServiceImpl implements AddressService {

    @Resource
    private AddressDao addressDao;

    @Override
    public List<Address> getAllShopByUserId(int userId) {



        return addressDao.getAllShopByUserId(userId);
    }

    @Override
    public int deleteAddress(int id) {
        return addressDao.deleteAddressById(id);
    }

    @Override
    public void updateAddressById(Address address) {
        addressDao.updateAddressById(address);
    }

    @Override
    public void addAddress(Address address) {
        addressDao.addAddress(address);
    }
    
}
